package com.stylefeng.guns.modular.system.model;

import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableName;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

/**
 * <p>
 * 
 * </p>
 *
 * @author stylefeng123
 * @since 2018-07-03
 */
@TableName("cash_expenditure")
public class CashExpenditure extends Model<CashExpenditure> {

    private static final long serialVersionUID = 1L;

    /**
     * 主键id
     */
    private Integer id;
    /**
     * 平台编号
     */
    private String platform;

    /**
     * 收支类型(1-收入，2-支出)
     */
    private Integer type;
    /**
     * 收支明细id
     */
    private Integer detailsId;
    /**
     * 收支金额
     */
    private Double money;
    /**
     * 余额
     */
    private Double balance;

    /**
     * 订单号
     */
    @TableField("order_number")
    private String orderNumber;

    /**
     * 支付小计
     */
    @TableField(exist = false)
    private Double payoutTatol;


    /**
     * 应收应付往来客户
     */
    private String customer;



    /**
     * 摘要
     */
    private String note;
    /**
     * 报表统计时间
     */
    @TableField("rev_date")
    @DateTimeFormat(pattern="yyyy-MM-dd")
    private Date revDate;
    /**
     * 创建时间
     */
    private Date creattime;
    /**
     * 更新时间
     */
    private Date updatetime;


    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getPlatform() {
        return platform;
    }

    public void setPlatform(String platform) {
        this.platform = platform;
    }


    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public Integer getDetailsId() {
        return detailsId;
    }

    public void setDetailsId(Integer detailsId) {
        this.detailsId = detailsId;
    }

    public Double getMoney() {
        return money;
    }

    public void setMoney(Double money) {
        this.money = money;
    }

    public Double getBalance() {
        return balance;
    }

    public void setBalance(Double balance) {
        this.balance = balance;
    }


    public String getNote() {
        return note;
    }

    public void setNote(String note) {
        this.note = note;
    }

    public Date getRevDate() {
        return revDate;
    }

    public void setRevDate(Date revDate) {
        this.revDate = revDate;
    }

    public Date getCreattime() {
        return creattime;
    }

    public void setCreattime(Date creattime) {
        this.creattime = creattime;
    }

    public Date getUpdatetime() {
        return updatetime;
    }

    public void setUpdatetime(Date updatetime) {
        this.updatetime = updatetime;
    }

    public Double getPayoutTatol() {
        return payoutTatol;
    }

    public void setPayoutTatol(Double payoutTatol) {
        this.payoutTatol = payoutTatol;
    }

    public String getOrderNumber() {
        return orderNumber;
    }

    public void setOrderNumber(String orderNumber) {
        this.orderNumber = orderNumber;
    }

    public static long getSerialVersionUID() {
        return serialVersionUID;
    }


    public String getCustomer() {
        return customer;
    }

    public void setCustomer(String customer) {
        this.customer = customer;
    }

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

    @Override
    public String toString() {
        return "CashExpenditure{" +
        "id=" + id +
        ", platform=" + platform +
        ", type=" + type +
        ", detailsId=" + detailsId +
        ", money=" + money +
        ", balance=" + balance +
        ", note=" + note +
        ", revDate=" + revDate +
        ", creattime=" + creattime +
        ", updatetime=" + updatetime +
        "}";
    }


    public static enum Enum_Type {
        //1:收入,2:支出
        收入(1, "收入"), 支出(2, "支出");
        public Integer value;
        public String desc;

        private Enum_Type(Integer _Value, String _Desc) {
            this.value = _Value;
            this.desc = _Desc;
        }
    }



    public static enum Enum_DetailType {
        生活成本费用(1, "生活成本费用"), 市场推广(2, "市场推广"),借贷(3, "借贷"),手续费(4, "手续费"),其他费用(5,"其他费用"),市场费用(6,"市场费用");
        public Integer value;
        public String desc;

        private Enum_DetailType(Integer _Value, String _Desc) {
            this.value = _Value;
            this.desc = _Desc;
        }
    }

    public static enum Enum_DetailTypes {
        //1:披索,2:人民币
        工资薪酬(1, "工资薪酬"), 食堂及补贴(3, "食堂及补贴"),房租费用(4, "房租费用"),水费(5, "水费"),电费(6,"电费"),网络费用(7,"网络费用"),
        机票费用(8,"机票费用"),签证及保关(9,"签证及保关"),办公费用(10,"办公费用"),其他杂费(11,"其他杂费"),应收(16,"应收"),应付(17,"应付"),借出PS(29,"借出PS");
        public int value;
        public String desc;

        private Enum_DetailTypes(int _Value, String _Desc) {
            this.value = _Value;
            this.desc = _Desc;
        }
    }
}
